//*****************************************************************************
//
// Copyright, (C) 2000-2005 Quantic Dream SA
//
// These coded instructions, statements and computer programs contain
// unpublished information, proprietary to Quantic Dream SA and are 
// protected by French and EEC copyright laws. They may not be 
// disclosed to third parties or copied or duplicated, in whole or in part, 
// without prior written consent of Quantic Dream SA
//
// Unpublished-rights reserved under the Copyright Laws of the EEC.
//
//*****************************************************************************
//
//	CLASS:	QtRender
//
//	JJA : 2012-07-23 - Created
//*****************************************************************************

#include "qtrender.h"
#include "QtRenderWidget.h"

#include <QHBoxLayout>
#include <QGLFormat>

//=============================================================================
//	CODE STARTS HERE
//=============================================================================

//-----------------------------------------------------------------------------
//! @brief		QtRender constructor
//! @details		
//! @param		
//! @return		
//! @author		JJA : 2012-07-19
//-----------------------------------------------------------------------------
QtRender::QtRender(QWidget *	parent, 
				   Qt::WFlags	flags)
: QMainWindow(parent, flags)
{
	QGLFormat glFormat;

	ui.setupUi(this);

    glFormat.setVersion( 4, 0 );
    glFormat.setProfile( QGLFormat::CoreProfile );
	glFormat.setDoubleBuffer( true );

	_pRenderWidget = new QtRenderWidget( glFormat, ui.centralWidget );
	ui.renderLayout->addWidget( _pRenderWidget );
}

//-----------------------------------------------------------------------------
//! @brief		QtRender destructor
//! @details		
//! @param		
//! @return		
//! @author		JJA : 2012-07-19
//-----------------------------------------------------------------------------
QtRender::~QtRender()
{
	
}

//=============================================================================
//	CODE ENDS HERE
//=============================================================================
